/*============================================================================
 PROJECT: TalkWrench
 FILE:    Contants.h
 AUTHOR:  Khoai Nguyen
 =============================================================================*/

#define kUserId                                 @"kUserId"

/* depredecations */
typedef enum {
    MKTextAlignmentLeft = 0,
    MKTextAlignmentCenter,
    MKTextAlignmentRight,
} MKTextAlignment;

typedef enum {
    MKLineBreakModeWordWrap = 0,            // Wrap at word boundaries
    MKLineBreakModeCharacterWrap,           // Wrap at character boundaries
    MKLineBreakModeClip,                    // Simply clip when it hits the end of the rect
    MKLineBreakModeHeadTruncation,          // Truncate at head of line: "...wxyz". Will truncate multiline text on first line
    MKLineBreakModeTailTruncation,          // Truncate at tail of line: "abcd...". Will truncate multiline text on last line
    MKLineBreakModeMiddleTruncation,        // Truncate middle of line:  "ab...yz". Will truncate multiline text in the middle
} MKLineBreakMode;

#define SupportiOS(x)                           [[UIDevice currentDevice] hasSupportVersion:x]
#define SupportiOS7                             SupportiOS(7)

/* common color */
#define kDarkGrayColor                          0x484848
#define kLightGrayColor                         0xb1b1b1
#define kGreenColor                             0x91c519
#define kColorLabelInTextField                  0x7b5c18
#define kColorTextField                         0x5c5c5c
#define kColorDescriptionText                   0xcccccc
#define kBorderColor                            0xb8b8b8
#define kTextColor                              0x191717
#define kLineColor                              0xe4e4e4
#define kLightBlueColor                         0x005c9c
#define kAvatarBorderColor                      0xaeaeae

/*----------------------------------------------------------------------------
 Method:      Tamnn's code   NexleSoft
 -----------------------------------------------------------------------------*/

#define kProfileImageBlurRadius                 50.0f
#define KReceiveMessageNotification             @"KReceiveMessageNotification"
#define KSendMessageNotification                @"KSendMessageNotification"
#define kXMPPRoomDidJoint                       @"kXMPPRoomDidJoint"
#define kXMPPRoomDidCreate                      @"kXMPPRoomDidCreate"
#define kXMPPUserDidJointToConversation         @"kXMPPUserDidJointToConversation"
#define kXMPPOccupantDidJoin                    @"kXMPPOccupantDidJoin"
#define kXMPPOccupantDidLeave                   @"kXMPPOccupantDidLeave"

/* size macros */
#define kCornerRadius                           IS_IPAD ? 10 : 5
#define kIconPadding                            IS_IPAD ? 17 : 5
#define kTextFieldPadding                       IS_IPAD ? 80 : 40
#define kTextFontSize                           IS_IPAD ? 24 : 13
#define kBorderHeight                           IS_IPAD ? 0.5 : 0.5
#define kLeftMarginTextBox                      IS_IPAD ? 20 : 10

/*----------------------------------------------------------------------------
 Notifications in the app
 -----------------------------------------------------------------------------*/
#define kAuthenticationSucceededEventNotification   @"kAuthenticationSucceededEventNotification"
#define kAuthenticationFailedEventNotification      @"kAuthenticationFailedEventNotification"
#define kUpdatedProfileInformationNotification      @"kUpdatedProfileInformationNotification"
#define kChangedSelectedPlaceNotification           @"kChangedSelectedPlaceNotification"
#define kAddedNewPlaceCommentNotification           @"kAddedNewPlaceCommentNotification"
#define kAddedNewDealCommentNotification            @"kAddedNewDealCommentNotification"
#define kDeactivatedDealNotification                @"kDeactivatedDealNotification"
#define kReactivatedDealNotification                @"kReactivatedDealNotification"

/*----------------------------------------------------------------------------
Common Texts
 -----------------------------------------------------------------------------*/
#define kNotAvailableString                     NSLocalizedString(@"Not Available", @"Error Message")
#define kNotHavePermissionMessage               NSLocalizedString(@"You don't have permission to access this function.", @"Error Message")